﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="OutboundEdit.aspx.cs" Inherits="DuJianliang.ApplicationPlatform.Outbound.OutboundEdit" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title></title>
    <script type="text/javascript">
        function showPage(url, width, height) {
            window.showModalDialog(encodeURI(url), "", "dialogWidth=" + width + ";dialogHeight=" + height);
        }

        function showSelectCustomer() {
            var retValue = window.showModalDialog(encodeURI("SelectCustomer.aspx"), "", "dialogWidth=800px;dialogHeight=600px");
            if (retValue != "" && typeof (retValue) != "undefined") {
                document.getElementById('<%=txtToUnit.ClientID%>').value = retValue;
            }
            return false;
        }
    </script>
</head>
<body style="font-size:12px">
    <form id="form1" runat="server">
    <div style="text-align:center; height:30px; font-size:20px;">产品出库通知单</div>
    <table width="100%">
        <tr>
            <td style="width:150px">编号：<asp:Label ID="lblCode" runat="server"></asp:Label></td>
            <td style="width:150px">日期：<asp:Label ID="lblDate" runat="server"></asp:Label></td>
            <td style="width:250px">出库根据：<asp:TextBox ID="txtOutboundBy" runat="server"></asp:TextBox></td>
            <td style="width:300px">发往单位：<asp:TextBox ID="txtToUnit" runat="server"></asp:TextBox>
            <input id="btnSelectCustomer" type="button" value="选择" onclick="showSelectCustomer();" />      
            </td>
            <td align="right">
                <asp:Button ID="btnOK" runat="server" Text="确定" onclick="btnOK_Click" />
                <asp:Button ID="btnReturn" runat="server" Text="返回" onclick="btnReturn_Click" />
                <asp:Button ID="btnAdd" runat="server" Text="选择" onclick="btnAdd_Click" />        
            </td>
        </tr>
    </table>
    <div>
        <asp:GridView ID="gridView" runat="server" AutoGenerateColumns="False" 
            CellPadding="4" Font-Size="9pt" ForeColor="#333333" GridLines="Both"
                    Width="100%" DataKeyNames="ID" onrowcommand="gridView_RowCommand">            
                    <Columns>
                        <asp:BoundField HeaderText="名称" DataField="ItemName" />
                        <asp:BoundField HeaderText="型号" DataField="ItemCode"  />
                        <asp:BoundField HeaderText="件号" DataField="PartName"  />
                        <asp:BoundField HeaderText="数量" DataField="ProductCount"  />
                        <asp:BoundField HeaderText="备注" DataField="Remark"  />              
                        <asp:TemplateField HeaderText="操作" ItemStyle-Width="50px">
                            <ItemTemplate>
                                <asp:Button ID="btnDelete" runat="server" Text="删除" OnClientClick="return confirm('您确定要删除该记录吗？');" CommandName="del"  CommandArgument='<%# Eval("ID") %>' Height="18px"></asp:Button>
                            </ItemTemplate>
                        </asp:TemplateField>
                    </Columns>
                    <HeaderStyle BackColor="#DFE8F6" Font-Bold="True" ForeColor="#333333" Height="20px"/>    
                    <RowStyle BackColor="#FAFAFA" ForeColor="#333333" Height="20px" HorizontalAlign="Center"/>
                    <EmptyDataTemplate>
                        <div style="text-align:center; margin-top:20px; margin-bottom:20px;">没有已选择的数据。</div>        
                    </EmptyDataTemplate>
                </asp:GridView>
    </div>
    </form>
</body>
</html>
